package com.hmall.api.controller;

import com.hmall.api.dto.PayOrderDTO;
import com.hmall.api.fallback.OrderClientFallbackFactory;
import com.hmall.api.fallback.PayClientFallbackFactory;
import org.springframework.cloud.openfeign.FeignClient;
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.PathVariable;
import org.springframework.web.bind.annotation.PutMapping;

@FeignClient(value = "pay-service",fallbackFactory = PayClientFallbackFactory.class)
public interface PayClient {

    @GetMapping("pay-orders/biz/{orderId}")
    public PayOrderDTO getByOrderId(@PathVariable("orderId") Long orderId);
}
